package cn.lg.soar.activiti.mapper;

import cn.lg.soar.activiti.api.model.HistoryTaskDTO;
import cn.lg.soar.activiti.api.model.TaskDTO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.activiti.engine.repository.Model;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Set;

/**
 * @author luguoxiang
 * 开源项目：https://gitee.com/lgx1992/lg-soar 求star！请给我star！请帮我点个star！
 */
@Mapper
public interface ActivitiMapper extends BaseMapper<Model> {

	List<TaskDTO> tasks(
			@Param("tenantId") String tenantId,
			@Param("processKey") String processKey,
			@Param("businessKeys") Set<String> businessKeys,
			@Param("candidates") Set<String> candidates
	);

	List<HistoryTaskDTO> historyTasks(
			@Param("tenantId") String tenantId,
			@Param("processKey") String processKey,
			@Param("businessId") String businessId
	);

}
